This invention relates to the calibration of magnetic compasses to compensate for local disturbance of the magnetic field caused by the structure of the vehicle within which the compass is mounted.
The ideal non-disturbed locus of a vector representing the magnitude of x,y and z signals output by a 3 axis magnetometer is a sphere centered on the origin of the x,y and z axes; however, due to disturbance caused by the ferromagnetic structure of the vehicle carrying the magnetometer, the locus is transformed from a sphere to an ellipsoid offset from the origin of the x,y and z axes. Therefore, in order to take account of the transformation and offset of the locus and thus to obtain compensated x,y and z data it is necessary to apply a compensation which reverts the offset ellipsoid locus to the sphere located at the origin of the body axes.
As a first step in this method, it is necessary to derive data which defines the ellipsoid representing the disturbed field. In published U.K. Application 2,128,749A, for example, the vehicle is moved through a setting routine to obtain 9 calibration points to allow determination of the coefficients of x,y and z in the equation: EQU ax.sup.2 +by.sup.2 +cz.sup.2 +2fyz+2gzx+2hxy+2ux+2vy+2wz=d.sup.2
where
x is the magnetic field sensed in the x direction PA1 y is the magnetic field sensed in the y direction PA1 z is the magnetic field sensed in the z direction PA1 (i) three magnetic sensors responsive to respective nominally orthogonal components of the disturbed magnetic field acting along respective nominally orthogonal body axes of the vehicle for producing signals corresponding to the components; PA1 (ii) data storage means for accumulating data output by the sensors during a setting maneuver of the vehicle; PA1 (iii) data processing means for processing data stored in the data storage means to fit a generalized reduced quadric equation having six or less coefficients and defining an ellipsoid representing the locus of values of the signals and for determining the coefficients; PA1 (iv) calibration means for deriving from the coefficients a calibration function for adjusting values output by the magnetic sensors so that the locus of adjusted values is a spheroid centered on the origin of the body axes, and PA1 (v) compensation means for receiving raw data from the magnetic sensors and for implementing the calibration function thereby to obtain signals corresponding to orthogonal components of the magnetic field in which the disturbance has been compensated. PA1 a is a 6.times.1 vector comprising the coefficients a,b,h,p,q and s; PA1 A is a 6.times.6 accumulation matrix array containing products of x,y and z data; and PA1 v is a 6.times.1 accumulation vector containing products of x,y and z data. PA1 (i) three magnetic sensors responsive to respective nominally orthogonal components of the disturbed magnetic field acting along respective orthogonal body axes of the vehicle for producing signals corresponding to the components; PA1 (ii) model coefficient storage means for storing initial values for the coefficients of a generalized quadric equation defining an ellipsoid representing the locus of values of signals x,y and z output by the magnetic sensors; PA1 (iii) adaptive processing means for receiving and processing continuously data from the sensors to update the coefficients to compensate for variations in the disturbance of the magnetic field; PA1 (iv) calibration means for deriving from the updated coefficients a,b,h,p,q and s a calibration function for adjusting the values of x,y,z output by the magnetic sensors so that the locus of values of signals x,y and z is transformed into a sphere centered on the origin of the body axes of the vehicle; PA1 (v) compensation means for receiving raw data from the magnetic sensors and for implementing the calibration function thereby to obtain signals corresponding to orthogonal components of the magnetic field in which the disturbance has been compensated. PA1 (i) three magnetic forces responsive to respective nominally orthogonal components of the disturbed magnetic field acting along respective body axes of the vehicle for producing signals corresponding to the components; PA1 (ii) accumulation data storage means for accumulating data output by the sensors; PA1 (iii) calibration data storage means for storing data representing a matrix relating a vector representing the coefficients to a vector representing the accumulation data contained in the accumulation data storage means; and PA1 (iv) signal processing means for processing data output by the magnetic sensors and for updating the data stored in the calibration data storage means in accordance therewith to compensate for variations in the disturbance to the magnetic field.
This method involves finding the inverse of a 9.times.9 matrix and as such requires considerable computing power. In addition, it is found that with some selections of calibration points the above equation does not converge to an ellipsoid but instead fits the points to a non-ellipsoidal shape thus preventing implementation of valid compensation. Also, in U.K. Application 2,128,749A, once the coefficients have been determined they are used to determine the translation needed to bring the ellipsoidal locus to the origin of the x,y and z axes, the amount of rotation to bring the major axis of the ellipsoid into coincidence with the y axis, the amount of scaling of the x,y and z axes to bring the ellipsoid into a sphere, and the amount of rotation to return the sphere back to its original position.
U.S. Pat. No. 4,414,753 also discloses a similar form of magnetic compass calibration.